s = input()
print(s + ('s' if s[-1] != 's' else 'es'))
